
<!--可疑品流程表-->
<template>
  <div style="margin: 0;padding: 0">
    <el-container>
      <!--页面表头设计-->
      <el-header style="height: 39px">
        <el-link class="headMain" href="http://10.255.96.48:3404/">{{main.qualityManagementSystem}}</el-link>
        <span class="center-text">{{main.controlPlanManagement}}</span>
        <el-popover
            placement="top-start"
            title="用户信息"
            width="200"
            trigger="hover">
          <div style="margin-top: 10px">Name：{{useName}}</div>
          <div style="margin-top: 10px">ID:{{useId}}</div>
          <div style="margin-top: 10px" @click="logOut"><el-link>退出</el-link></div>
          <div class="headMain" slot="reference">{{useName}}</div>
        </el-popover>
      </el-header>
      <el-container>
        <el-aside width="200px" style="overflow-y: scroll">
          <div>
            <el-input
                :placeholder="main.filter"
                v-model="filterText"
                style="width: 100%">
            </el-input>
          </div>
          <el-tree
              style="margin: 10px 8px;"
              :data="treeControlPlan"
              :props="defaultProps"
              accordion
              @node-click="treeClick"
              :filter-node-method="filterNode"
              ref="tree"></el-tree>
        </el-aside>
        <el-container>
          <!--主题设计-->
          <el-main class="el-main" style="height: calc(80vh - 83px);overflow: auto">
            <el-tabs v-model="activeName" @tab-click="handleClick">
              <div style="display: flex; align-items: center; gap: 5px; margin-bottom: 5px; flex-wrap: nowrap;">
                <span style="white-space: nowrap;">{{pageVal.workshop}}{{firstTree}}</span>
                <el-divider direction="vertical"></el-divider>
                <span style="white-space: nowrap;">{{pageVal.product}}{{secondTree}}</span>
                <el-divider direction="vertical"></el-divider>
                <span style="white-space: nowrap;">{{pageVal.op}}{{thirdTree}}</span>
                <!-- 添加 flex-shrink:0 防止按钮被压缩 -->
                <span style="flex-shrink: 0; margin-left: auto;">
                  <el-upload
                    ref="excelUpload"
                    action="http://10.255.96.48:3499/russiaEngine/"
                    :show-file-list="false"
                    :auto-upload="false"
                    accept=".xlsx, .xls"
                    :on-change="handleUploadSuccess"
                    :on-error="handleUploadError">
                    <el-button size="mini">{{pageVal.excel}}</el-button>
                  </el-upload>
                </span>
              </div>
              <el-tab-pane :label="pageVal.controlPlan" name="controlPlan">
                <div :key="componentKey">
                  <el-table
                      :data="controlPlanData"
                      style="width: 100%"
                      height="68vh"
                      size="mediut">
                    <el-table-column
                        :prop="controlPlan.operation"
                        :label="pageVal.processName"
                        align="center"
                        width="150"
                        v-slot:default="scope">
                      <span v-if="languageS==='chinese'">{{scope.row.operation}}</span>
                      <span v-if="languageS==='english'">{{scope.row.operation_english}}</span>
                      <span v-if="languageS==='russian'">{{scope.row.operation_russian}}</span>
                    </el-table-column>
                    <el-table-column
                        :prop="controlPlan.device"
                        :label="pageVal.device"
                        width="180"
                        align="center"
                        v-slot:default="scope">
                      <span v-if="languageS==='chinese'">{{scope.row.device}}</span>
                      <span v-if="languageS==='english'">{{scope.row.device_english}}</span>
                      <span v-if="languageS==='russian'">{{scope.row.device_russian}}</span>
                    </el-table-column>
                    <el-table-column :label="pageVal.characteristic" align="center">
                      <el-table-column
                          :prop="controlPlan.number_order"
                          :label="pageVal.number"
                          width="120"
                          align="center">
                      </el-table-column>
                      <el-table-column
                          :prop="controlPlan.product1"
                          :label="pageVal.product"
                          width="120"
                          align="center"
                          v-slot:default="scope">
                        <span v-if="languageS==='chinese'">{{scope.row.product}}</span>
                        <span v-if="languageS==='english'">{{scope.row.product_english}}</span>
                        <span v-if="languageS==='russian'">{{scope.row.product_russian}}</span>
                      </el-table-column>
                      <el-table-column
                          :prop="controlPlan.process_use"
                          :label="pageVal.process"
                          width="120"
                          align="center"
                          v-slot:default="scope">
                        <span v-if="languageS==='chinese'">{{scope.row.process_use}}</span>
                        <span v-if="languageS==='english'">{{scope.row.process_use_english}}</span>
                        <span v-if="languageS==='russian'">{{scope.row.process_use_russian}}</span>
                      </el-table-column>
                    </el-table-column>
                    <el-table-column
                        prop="characteristic"
                        :label="pageVal.characteristicClassification"
                        width="120"
                        align="center">
                    </el-table-column>
                    <el-table-column
                        :label="pageVal.method"
                        align="center">
                      <el-table-column
                          :label="pageVal.tolerance"
                          width="250px"
                          align="center"
                          :prop="controlPlan.specification"
                          fixed
                          v-slot:default="scope">
                        <span v-if="languageS==='chinese'">{{scope.row.specification}}</span>
                        <span v-if="languageS==='english'">{{scope.row.specification_english}}</span>
                        <span v-if="languageS==='russian'">{{scope.row.specification_russian}}</span>
                      </el-table-column>
                      <el-table-column
                          :label="pageVal.measure"
                          width="110px"
                          align="center"
                          :prop="controlPlan.measure"
                          v-slot:default="scope">
                        <span v-if="languageS==='chinese'">{{scope.row.measure}}</span>
                        <span v-if="languageS==='english'">{{scope.row.measure_english}}</span>
                        <span v-if="languageS==='russian'">{{scope.row.measure_russian}}</span>
                      </el-table-column>
                      <el-table-column
                          :label="pageVal.capacity"
                          width="100px"
                          align="center"
                          :prop="controlPlan.capacity"
                          v-slot:default="scope">
                        <span v-if="languageS==='chinese'">{{scope.row.capacity}}</span>
                        <span v-if="languageS==='english'">{{scope.row.capacity_english}}</span>
                        <span v-if="languageS==='russian'">{{scope.row.capacity_russian}}</span>
                      </el-table-column>
                      <el-table-column
                          :label="pageVal.frequency"
                          width="100px"
                          align="center"
                          :prop="controlPlan.frequency"
                          v-slot:default="scope">
                        <span v-if="languageS==='chinese'">{{scope.row.frequency}}</span>
                        <span v-if="languageS==='english'">{{scope.row.frequency_english}}</span>
                        <span v-if="languageS==='russian'">{{scope.row.frequency_russian}}</span>
                      </el-table-column>
                      <el-table-column
                          :label="pageVal.controlMethod"
                          width="100px"
                          align="center"
                          :prop="controlPlan.method"
                          v-slot:default="scope">
                        <span v-if="languageS==='chinese'">{{scope.row.method}}</span>
                        <span v-if="languageS==='english'">{{scope.row.method_english}}</span>
                        <span v-if="languageS==='russian'">{{scope.row.method_russian}}</span>
                      </el-table-column>
                      <el-table-column
                          :label="pageVal.department"
                          width="100px"
                          align="center"
                          v-slot:default="scope">
                        <el-link v-if="languageS==='chinese'">{{scope.row.department.split('/')[0]}}</el-link>
                        <el-link v-if="languageS==='english'">{{scope.row.department.split('/')[1]}}</el-link>
                        <el-link v-if="languageS==='russian'">{{scope.row.department.split('/')[2]}}</el-link>
                      </el-table-column>
                    </el-table-column>
                    <el-table-column
                        :label="pageVal.reaction"
                        width="100px"
                        align="center"
                        prop="reaction">
                    </el-table-column>
                    <el-table-column :label="pageVal.edit" width="220px" v-slot:default="scope" v-if="usePower===1">
                      <el-link type="primary" @click="controlPlanDialogShow(scope,1)">{{pageVal.edit}}&nbsp;&nbsp;</el-link>
                      <el-link type="primary" @click="deleteDataShow('deleteControlPlanOneRow',scope)">{{pageVal.delete}}&nbsp;&nbsp;</el-link>
                      <el-link type="primary" @click="controlPlanDialogShow(scope,3)">{{pageVal.insertDownwards}}&nbsp;&nbsp;</el-link>
                      <el-link type="primary" @click="controlPlanDialogShow(scope,4)">{{pageVal.insertUpwards}}</el-link>
                    </el-table-column>
                    <el-table-column label="频次检测" width="90px" v-slot:default="scopeTesting" v-if="usePower===2">
                      <span v-if="scopeTesting.row.controlTesting !==''">启用</span>&nbsp;&nbsp;
                      <el-link type="primary" @click="testing(scopeTesting,1)" v-if="scopeTesting.row.product!=='请输入'">编辑</el-link>
                    </el-table-column>
                  </el-table>
                </div>
              </el-tab-pane>
            </el-tabs>
          </el-main>
          <el-footer class="el-footer" style="height: 44px">
            <el-button plain size="mini" @click="languageSelect('chinese')">中  文</el-button>
            <el-button plain size="mini" @click="languageSelect('russian')">Русский язык</el-button>
            <el-button plain size="mini" @click="languageSelect('english')">English</el-button>
          </el-footer>
        </el-container>
      </el-container>
    </el-container>

    <!--弹窗放置区-->
    <!--EXCEL批量插入控制计划用到的弹窗-->
    <el-dialog
        :title="titleMessage"
        :visible.sync="controlPlanExcelAddDialog"
        width="80%"
        :before-close="handleClose">
      <div style="color: red;text-align: left;font-size: 14px">{{dialogText}}</div>
      <div style="overflow: auto">
        <el-table
            :data="controlPlanDataExcel"
            style="width: 100%"
            height="500px"
            size="medium"
            border>
          <!-- 零件/过程编号（多语言） -->
          <el-table-column
              label="零件/过程编号"
              width="200"
              align="center"
          >
            <el-table-column
                prop="process_number"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="process_number_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="process_number_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 机器/夹具/装置/工装（多语言） -->
          <el-table-column
              label="机器/夹具/装置/工装"
              width="250"
              align="center"
          >
            <el-table-column
                prop="device"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="device_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="device_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 过程名称/操作描述（多语言） -->
          <el-table-column
              label="过程名称/操作描述"
              width="250"
              align="center"
          >
            <el-table-column
                prop="operation"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="operation_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="operation_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 编号 -->
          <el-table-column
              prop="number_order"
              label="编号"
              width="120"
              align="center"
          />

          <!-- 产品相关（多语言） -->
          <el-table-column
              label="产品信息"
              width="250"
              align="center"
          >
            <el-table-column
                prop="product"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="product_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="product_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 过程使用（多语言） -->
          <el-table-column
              label="过程信息"
              width="250"
              align="center"
          >
            <el-table-column
                prop="process_use"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="process_use_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="process_use_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 特殊特性 -->
          <el-table-column
              prop="characteristic"
              label="特殊特性分类"
              width="150"
              align="center"
          />

          <!-- 规范/公差（多语言） -->
          <el-table-column
              label="规范/公差"
              width="300"
              align="center"
          >
            <el-table-column
                prop="specification"
                label="中文"
                width="150"
            />
            <el-table-column
                prop="specification_english"
                label="英文"
                width="180"
            />
            <el-table-column
                prop="specification_russian"
                label="俄文"
                width="200"
            />
          </el-table-column>

          <!-- 测量技术（多语言） -->
          <el-table-column
              label="测量技术"
              width="250"
              align="center"
          >
            <el-table-column
                prop="measure"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="measure_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="measure_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 容量（多语言） -->
          <el-table-column
              label="容量"
              width="200"
              align="center"
          >
            <el-table-column
                prop="capacity"
                label="中文"
                width="100"
            />
            <el-table-column
                prop="capacity_english"
                label="英文"
                width="100"
            />
            <el-table-column
                prop="capacity_russian"
                label="俄文"
                width="100"
            />
          </el-table-column>

          <!-- 频率（多语言） -->
          <el-table-column
              label="频率"
              width="200"
              align="center"
          >
            <el-table-column
                prop="frequency"
                label="中文"
                width="100"
            />
            <el-table-column
                prop="frequency_english"
                label="英文"
                width="100"
            />
            <el-table-column
                prop="frequency_russian"
                label="俄文"
                width="100"
            />
          </el-table-column>

          <!-- 控制方法（多语言） -->
          <el-table-column
              label="控制方法"
              width="250"
              align="center"
          >
            <el-table-column
                prop="method"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="method_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="method_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 责任部门（多语言） -->
          <el-table-column
              label="责任部门"
              width="250"
              align="center"
          >
            <el-table-column
                prop="department"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="department_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="department_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 反应计划 -->
          <el-table-column
              prop="reaction"
              label="反应计划"
              width="120"
              align="center"
          />

          <!-- 产品图号 -->
          <el-table-column
              prop="drawing"
              label="产品图号"
              width="150"
              align="center"
          />

          <!-- 工序号 -->
          <el-table-column
              prop="op"
              label="工序号"
              width="100"
              align="center"
          />

          <!-- 车间（多语言） -->
          <el-table-column
              label="车间"
              width="200"
              align="center"
          >
            <el-table-column
                prop="workshop"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="workshop_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="workshop_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>
        </el-table>
      </div>
      <span slot="footer" class="dialog-footer">
        <el-button @click="controlPlanExcelAddDialog = false">取 消</el-button>
        <el-button type="primary" @click="controlPlanExcelCoverAddOk">删除原有再插入</el-button>
        <el-button type="primary" @click="controlPlanExcelAddOk">直接插入所有</el-button>
      </span>
    </el-dialog>
    <!--控制计划的修改excel区-->
    <el-dialog
        :title="titleMessage"
        :visible.sync="controlPlanEditDialog"
        width="80%"
        :before-close="handleClose">
      <div style="color: red;text-align: left;font-size: 14px">{{dialogText}}</div>
      <div style="overflow: auto">
        <el-table
            :data="controlPlanDataExcel"
            style="width: 100%"
            height="500px"
            size="medium"
            border>
          <!-- 零件/过程编号（多语言） -->
          <el-table-column
              label="零件/过程编号"
              width="200"
              align="center"
          >
            <el-table-column
                prop="process_number"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="process_number_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="process_number_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 机器/夹具/装置/工装（多语言） -->
          <el-table-column
              label="机器/夹具/装置/工装"
              width="250"
              align="center"
          >
            <el-table-column
                prop="device"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="device_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="device_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 过程名称/操作描述（多语言） -->
          <el-table-column
              label="过程名称/操作描述"
              width="250"
              align="center"
          >
            <el-table-column
                prop="operation"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="operation_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="operation_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 编号 -->
          <el-table-column
              prop="number_order"
              label="编号"
              width="120"
              align="center"
          />

          <!-- 产品相关（多语言） -->
          <el-table-column
              label="产品信息"
              width="250"
              align="center"
          >
            <el-table-column
                prop="product"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="product_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="product_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 过程使用（多语言） -->
          <el-table-column
              label="过程信息"
              width="250"
              align="center"
          >
            <el-table-column
                prop="process_use"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="process_use_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="process_use_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 特殊特性 -->
          <el-table-column
              prop="characteristic"
              label="特殊特性分类"
              width="150"
              align="center"
          />

          <!-- 规范/公差（多语言） -->
          <el-table-column
              label="规范/公差"
              width="300"
              align="center"
          >
            <el-table-column
                prop="specification"
                label="中文"
                width="150"
            />
            <el-table-column
                prop="specification_english"
                label="英文"
                width="150"
            />
            <el-table-column
                prop="specification_russian"
                label="俄文"
                width="150"
            />
          </el-table-column>

          <!-- 测量技术（多语言） -->
          <el-table-column
              label="测量技术"
              width="250"
              align="center"
          >
            <el-table-column
                prop="measure"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="measure_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="measure_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 容量（多语言） -->
          <el-table-column
              label="容量"
              width="200"
              align="center"
          >
            <el-table-column
                prop="capacity"
                label="中文"
                width="100"
            />
            <el-table-column
                prop="capacity_english"
                label="英文"
                width="100"
            />
            <el-table-column
                prop="capacity_russian"
                label="俄文"
                width="100"
            />
          </el-table-column>

          <!-- 频率（多语言） -->
          <el-table-column
              label="频率"
              width="200"
              align="center"
          >
            <el-table-column
                prop="frequency"
                label="中文"
                width="100"
            />
            <el-table-column
                prop="frequency_english"
                label="英文"
                width="100"
            />
            <el-table-column
                prop="frequency_russian"
                label="俄文"
                width="100"
            />
          </el-table-column>

          <!-- 控制方法（多语言） -->
          <el-table-column
              label="控制方法"
              width="250"
              align="center"
          >
            <el-table-column
                prop="method"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="method_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="method_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 责任部门（多语言） -->
          <el-table-column
              label="责任部门"
              width="250"
              align="center"
          >
            <el-table-column
                prop="department"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="department_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="department_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>

          <!-- 反应计划 -->
          <el-table-column
              prop="reaction"
              label="反应计划"
              width="120"
              align="center"
          />

          <!-- 产品图号 -->
          <el-table-column
              prop="drawing"
              label="产品图号"
              width="150"
              align="center"
          />

          <!-- 工序号 -->
          <el-table-column
              prop="op"
              label="工序号"
              width="100"
              align="center"
          />

          <!-- 车间（多语言） -->
          <el-table-column
              label="车间"
              width="200"
              align="center"
          >
            <el-table-column
                prop="workshop"
                label="中文"
                width="120"
            />
            <el-table-column
                prop="workshop_english"
                label="英文"
                width="120"
            />
            <el-table-column
                prop="workshop_russian"
                label="俄文"
                width="120"
            />
          </el-table-column>
        </el-table>
      </div>
      <span slot="footer" class="dialog-footer">
        <el-button @click="controlPlanExcelAddDialog = false">取 消</el-button>
        <el-button type="primary" @click="controlPlanExcelCoverAddOk">删除原有再插入</el-button>
        <el-button type="primary" @click="controlPlanExcelAddOk">直接插入所有</el-button>
  </span>
    </el-dialog>

    <!--删除某一条数据的弹窗-->
    <el-dialog
        :title="titleMessage"
        :visible.sync="deleteDataDialog"
        width="400px"
        :before-close="handleClose">
      <span>{{pageVal.sureToDelete}}</span>
      <span slot="footer" class="dialog-footer">
        <el-button @click="deleteDataDialog = false" size="mini">{{pageVal.cancel}}</el-button>
        <el-button type="primary"  size="mini" @click="deleteDataOk">{{pageVal.ok}}</el-button>
      </span>
    </el-dialog>
    <!--对控制计划内容进行增删改操作的弹窗-->
    <el-dialog
        :title="titleMessage"
        :visible.sync="controlPlanDialog"
        width="85%"
        :before-close="handleClose">
    <span>
      <!--放置修改的表单-->
      <el-form :inline="true" :model="controlPlanForm" status-icon ref="controlPlanForm" class="demo-form-inline" label-width="135px" >
        <div class="UploadS" style="text-align: left">
         <el-form-item label="零件/过程编号">

          <el-input v-model="controlPlanForm.process_number"
                    placeholder="零件/过程编号"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
         <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.process_number_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
         <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.process_number_russian"
                    placeholder="Russian"
                    type="textarea"
                    autosize></el-input>
        </el-form-item>
          <br>
        <el-form-item label="过程名称/操作描述">
          <el-input v-model="controlPlanForm.operation"
                    placeholder="过程名称/操作描述"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.operation_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.operation_russian"
                    placeholder="Russian"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
          <br>
        <el-form-item label="机器、夹具、装置、工装">
          <el-input v-model="controlPlanForm.device"
                    placeholder="机器、夹具、装置、工装"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.device_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.device_russian"
                    placeholder="Russian"
                    type="textarea"
                    autosize></el-input>
        </el-form-item>
         </div>
        <br>
        <div class="UploadS" style="text-align: left">
        <el-form-item label="编号">
          <el-input v-model="controlPlanForm.number_order"
                    placeholder="编号"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
          <br>
        <el-form-item label="产品">
          <el-input v-model="controlPlanForm.product"
                    placeholder="产品"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.product_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
         <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.product_russian"
                    placeholder="Russian"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <br>
        <el-form-item label="过程">
          <el-input v-model="controlPlanForm.process_use"
                    placeholder="过程"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.process_use_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.process_use_russian"
                    placeholder="Russian"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        </div>
        <br>
        <div class="UploadS" style="text-align: left">
        <el-form-item label="特殊特性分类">
          <el-input v-model="controlPlanForm.characteristic"
                    placeholder="特殊特性分类"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
          <br>
        <el-form-item label="产品/过程规范/公差" >
          <el-input v-model="controlPlanForm.specification"
                    placeholder="产品/过程规范/公差"
                    type="textarea"
                    class="el-input"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <br>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.specification_english"
                    placeholder="(English)"
                    type="textarea"
                    class="el-input"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <br>
        <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.specification_russian"
                    placeholder="(Russian)"
                    type="textarea"
                    class="el-input"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <br>
        <el-form-item label="评价/测量技术">
          <el-input v-model="controlPlanForm.measure"
                    placeholder="评价/测量技术"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.measure_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.measure_russian"
                    placeholder="Russian"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <br>
        <el-form-item label="容量">
          <el-input v-model="controlPlanForm.capacity"
                    placeholder="过程"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.capacity_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.capacity_russian"
                    placeholder="Russian"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <br>
        <el-form-item label="频率">
          <el-input v-model="controlPlanForm.frequency"
                    placeholder="过程"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.frequency_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.frequency_russian"
                    placeholder="Russian"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <br>
        <el-form-item label="控制方法">
          <el-input v-model="controlPlanForm.method"
                    placeholder="过程"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(English)">
          <el-input v-model="controlPlanForm.method_english"
                    placeholder="English"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        <el-form-item label="(Russian)">
          <el-input v-model="controlPlanForm.method_russian"
                    placeholder="Russian"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>
        </div>
        <br>
        <div class="UploadS" style="text-align: left">
          <el-form-item label="责任部门" prop="department" class="item">
            <el-select v-model="controlPlanForm.department" placeholder="请选择" size="small">
              <el-option
                  v-for="item in workshopOptions"
                  :key="item.value"
                  :label="item.label"
                  :value="item.value">
              </el-option>
            </el-select>
          </el-form-item>
        <el-form-item
            label="反应计划"
            prop="reaction">
          <el-input v-model="controlPlanForm.reaction"
                    placeholder="（请输入数字）"
                    type="textarea"
                    :autosize="{ minRows: 1, maxRows: 4}"></el-input>
        </el-form-item>

        </div>
        <br><br>
        <el-form-item>
      <el-button type="primary" @click="controlPlanDialogOk">提交</el-button>
      <el-button @click="controlPlanDialog=false">取消</el-button>
      </el-form-item>
    </el-form>
  </span>
    </el-dialog>
    <!--抽屉放置区域-->
  </div>
</template>

<script>

import * as XLSX from "xlsx";
import _ from "lodash";

export default {
  name: "controlPlanNew",
  data() {
    return {
      //用户权限相关的变量
      useName: '',//用户名称
      useId: '',//用户编号
      usePower: '',//用户权限
      //控制计划的标签绑定变量
      activeName:'controlPlan',
      //用户登录后默认为中文
      languageS: 'chinese',
      //切换语言，页面变量
      main: {
        qualityManagementSystem: '俄动力质量管理系统',
        controlPlanManagement: '控制计划管理',
        filter:'输入关键字进行过滤',
      },
      pageVal:{
        cancel:'取消',
        ok:'确定',
        sureToDelete:'确定删除数据吗？',

        controlPlan:'控制计划',
        workshop:'车间：',
        product:'产品：',
        op:'工序：',
        excel:'EXCEL上传',
        processName:'过程名称/操作描述',
        device:'机器、装置、夹具、工装',
        characteristic:'特性',
        number:'编号',
        product1:'产品',
        process:'过程',
        characteristicClassification:'特殊特性分类',
        method:'方法',
        tolerance:'产品/过程规范/公差',
        measure:'评价/测量技术',
        capacity:'容量',
        frequency:'频率',
        controlMethod:'控制方法',
        department:'责任部门',
        reaction:'反应计划',
        edit:'编辑',
        delete:'删除',
        insertDownwards:'向下插入',
        insertUpwards:'向上插入',
      },
      //点击树形结构，传出的变量，三级，
      firstTree:'',
      secondTree:'',
      thirdTree:'',

      //树形导航的变量
      treeControlPlan:[
        {label: '装配车间',
          children: [
          {
            label: '1000100XEB05',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP155'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP245'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP375'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'HL35'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG80'
              }
            ]
          },
          {
            label: '1000100XEB75',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP01'
              },
              {
                label: 'OP02'
              },
              {
                label: 'OP03'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG130'
              }
            ]
          },
          {
            label: '1000100XEN19',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP01'
              },
              {
                label: 'OP02'
              },
              {
                label: 'OP03'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390-1'
              },
              {
                label: 'OP390-2'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG130'
              }
            ]
          },
          {
            label: '1000100XEN38',
            children: [
              {
                label: 'OP00'
              },
              {
                label: 'OP01'
              },
              {
                label: 'OP02'
              },
              {
                label: 'OP03'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP10'
              },
              {
                label: 'OP20'
              },
              {
                label: 'OP30-1'
              },
              {
                label: 'OP30'
              },
              {
                label: 'OP40'
              },
              {
                label: 'OP50'
              },
              {
                label: 'OP60'
              },
              {
                label: 'OP70'
              },
              {
                label: 'OP80'
              },
              {
                label: 'OP90'
              },
              {
                label: 'OP100'
              },
              {
                label: 'OP105'
              },
              {
                label: 'OP120'
              },
              {
                label: 'OP130'
              },
              {
                label: 'OP140'
              },
              {
                label: 'OP150'
              },
              {
                label: 'OP160'
              },
              {
                label: 'OP170'
              },
              {
                label: 'OP180'
              },
              {
                label: 'OP190'
              },
              {
                label: 'OP200'
              },
              {
                label: 'OP210'
              },
              {
                label: 'OP220'
              },
              {
                label: 'OP230'
              },
              {
                label: 'OP240-1'
              },
              {
                label: 'OP240'
              },
              {
                label: 'OP250'
              },
              {
                label: 'OP260'
              },
              {
                label: 'OP270'
              },
              {
                label: 'OP275'
              },
              {
                label: 'OP280-1'
              },
              {
                label: 'OP280-2'
              },
              {
                label: 'OP280-3'
              },
              {
                label: 'OP280-4'
              },
              {
                label: 'OP280-5'
              },
              {
                label: 'OP290'
              },
              {
                label: 'OP300'
              },
              {
                label: 'OP310'
              },
              {
                label: 'OP320'
              },
              {
                label: 'OP330'
              },
              {
                label: 'OP340'
              },
              {
                label: 'OP350-1'
              },
              {
                label: 'OP350'
              },
              {
                label: 'OP360'
              },
              {
                label: 'OP370'
              },
              {
                label: 'OP380'
              },
              {
                label: 'OP390'
              },
              {
                label: 'OP400'
              },
              {
                label: 'OP410-1'
              },
              {
                label: 'OP410'
              },
              {
                label: 'OP420'
              },
              {
                label: 'OP430'
              },
              {
                label: 'OP440-1'
              },
              {
                label: 'OP440'
              },
              {
                label: 'OP450'
              },
              {
                label: 'OP460'
              },
              {
                label: 'OP470'
              },
              {
                label: 'OP480'
              },
              {
                label: 'OP490'
              },
              {
                label: 'OP500'
              },
              {
                label: 'OP510'
              },
              {
                label: 'OP520'
              },
              {
                label: 'OP530'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'HL10'
              },
              {
                label: 'HL20'
              },
              {
                label: 'HL30'
              },
              {
                label: 'GG10'
              },
              {
                label: 'GG20'
              },
              {
                label: 'GG30'
              },
              {
                label: 'GG40'
              },
              {
                label: 'GG45'
              },
              {
                label: 'GG50'
              },
              {
                label: 'GG130'
              }
            ]
          }
        ]},
        {
          label: '机加车间',
          children: [
            {
              label: '1002100XEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            {
              label: '1003100AEB75',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30A-1'
                },
                {
                  label: 'OP30A-2'
                },
                {
                  label: 'OP30B-1'
                },
                {
                  label: 'OP30B-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            },
            {
              label: '1002100XEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20-1'
                },
                {
                  label: 'OP20-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50-1'
                },
                {
                  label: 'OP50-2'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP75'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110-1'
                },
                {
                  label: 'OP110-2'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP135'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
              ]
            },
            {
              label: '1003100AEB05',
              children: [
                {
                  label: 'OP05'
                },
                {
                  label: 'OP10-1'
                },
                {
                  label: 'OP10-2'
                },
                {
                  label: 'OP20A-1'
                },
                {
                  label: 'OP20A-2'
                },
                {
                  label: 'OP20B-1'
                },
                {
                  label: 'OP20B-2'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30-2'
                },
                {
                  label: 'OP40-1'
                },
                {
                  label: 'OP40-2'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90-1'
                },
                {
                  label: 'OP90-2'
                },
                {
                  label: 'OP100-1'
                },
                {
                  label: 'OP100-2'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP110'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140-1'
                },
                {
                  label: 'OP140-2'
                },
                {
                  label: 'OP150-1'
                },
                {
                  label: 'OP150-2'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
              ]
            }
          ]
        }
      ],
      //导航筛选的变量
      filterText:'',
      //文件列表
      fileListExcel:[],
      //树形的导航用到的数据模板
      defaultProps: {
        children: 'children',
        label: 'label'
      },

      //控制计划的大表
      controlPlanData: [
        {
          //唯一标识，低代码的主键
          id:'',
          //创建时间
          create_time:'',
          //更新时间
          update_time:'',
          //创建人
          creator:'',
          //流程状态
          process_status:'',
          //更新人
          sys_update_user:'',
          //审核人
          sys_audit_user:'',
          //审核时间
          sys_audit_time:'',
          //逻辑删除
          sys_deleted:0,

          // 零件/过程编号（多语言字段组）
          process_number: '',       // 中文
          process_number_english: '', // 英文
          process_number_russian: '', // 俄文
          // 机器/夹具/装置/工装（多语言字段组）
          device: '',               // 中文
          device_english: '',       // 英文
          device_russian: '',       // 俄文
          // 过程名称/操作描述（多语言字段组）
          operation: '',            // 中文
          operation_english: '',    // 英文
          operation_russian: '',    // 俄文
          // 编号字段
          number_order: '',         // 记录编号
          // 产品相关字段（多语言字段组）
          product: '',              // 中文
          product_english: '',      // 英文
          product_russian: '',      // 俄文
          // 过程相关字段（多语言字段组）
          process_use: '',          // 中文
          process_use_english: '',  // 英文
          process_use_russian: '',  // 俄文
          // 特殊特性分类
          characteristic: '',       // 特殊特性类型标识
          // 规范公差相关字段（多语言字段组）
          specification: '',        // 中文
          specification_english: '',// 英文
          specification_russian: '',// 俄文
          // 测量技术相关字段（多语言字段组）
          measure: '',              // 中文
          measure_english: '',      // 英文
          measure_russian: '',      // 俄文
          // 容量相关字段（多语言字段组）
          capacity: '',             // 中文
          capacity_english: '',     // 英文
          capacity_russian: '',     // 俄文
          // 频率相关字段（多语言字段组）
          frequency: '',            // 中文
          frequency_english: '',    // 英文
          frequency_russian: '',    // 俄文
          // 控制方法相关字段（多语言字段组）
          method: '',               // 中文
          method_english: '',       // 英文
          method_russian: '',       // 俄文
          // 责任部门相关字段（多语言字段组）
          department: '',           // 中文
          department_english: '',   // 英文
          department_russian: '',   // 俄文
          // 反应计划标识（0-未处理 1-已处理）
          reaction: 0,
          // 产品图号
          drawing: '',
          // 工序号（数字类型）
          op: 0,
          // 车间名称相关字段（多语言字段组）
          workshop: '',
          // 记录顺序号（数字排序用）
          order_number: 0,
          //控制计划与品检关联字段
          control_testing:''
        }
      ],
      //控制计划的修改表单
      controlPlanForm:{
        //唯一标识，低代码的主键
        id:'',
        //创建时间
        create_time:'',
        //更新时间
        update_time:'',
        //创建人
        creator:'',
        //流程状态
        process_status:'',
        //更新人
        sys_update_user:'',
        //审核人
        sys_audit_user:'',
        //审核时间
        sys_audit_time:'',
        //逻辑删除
        sys_deleted:0,

        // 零件/过程编号（多语言字段组）
        process_number: '',       // 中文
        process_number_english: '', // 英文
        process_number_russian: '', // 俄文
        // 机器/夹具/装置/工装（多语言字段组）
        device: '',               // 中文
        device_english: '',       // 英文
        device_russian: '',       // 俄文
        // 过程名称/操作描述（多语言字段组）
        operation: '',            // 中文
        operation_english: '',    // 英文
        operation_russian: '',    // 俄文
        // 编号字段
        number_order: '',         // 记录编号
        // 产品相关字段（多语言字段组）
        product: '',              // 中文
        product_english: '',      // 英文
        product_russian: '',      // 俄文
        // 过程相关字段（多语言字段组）
        process_use: '',          // 中文
        process_use_english: '',  // 英文
        process_use_russian: '',  // 俄文
        // 特殊特性分类
        characteristic: '',       // 特殊特性类型标识
        // 规范公差相关字段（多语言字段组）
        specification: '',        // 中文
        specification_english: '',// 英文
        specification_russian: '',// 俄文
        // 测量技术相关字段（多语言字段组）
        measure: '',              // 中文
        measure_english: '',      // 英文
        measure_russian: '',      // 俄文
        // 容量相关字段（多语言字段组）
        capacity: '',             // 中文
        capacity_english: '',     // 英文
        capacity_russian: '',     // 俄文
        // 频率相关字段（多语言字段组）
        frequency: '',            // 中文
        frequency_english: '',    // 英文
        frequency_russian: '',    // 俄文
        // 控制方法相关字段（多语言字段组）
        method: '',               // 中文
        method_english: '',       // 英文
        method_russian: '',       // 俄文
        // 责任部门相关字段（多语言字段组）
        department: '',           // 中文
        department_english: '',   // 英文
        department_russian: '',   // 俄文
        // 反应计划标识（0-未处理 1-已处理）
        reaction: 0,
        // 产品图号
        drawing: '',
        // 工序号（数字类型）
        op: 0,
        // 车间名称相关字段（多语言字段组）
        workshop: '',
        // 记录顺序号（数字排序用）
        order_number: 0,
        //控制计划与品检关联字段
        control_testing:''
      },
      //记录用户要对表进行哪项操作，1.编辑 2.删除 3.向上插入 4.向下插入 5.插入
      controlPlanDoe:0,
      //记录用户当前点击了哪一行
      controlPlanScope:null,

      //判断用户要删除哪个数据
      deleteDataDoe:'',

      //控制控制计划大表中的多语言切换：
      controlPlan:{
        operation:'operation',
        device:'',
        number_order:'number_order',
        product:'product',
        process_use:'processUse',
        specification:'specification',
        measure:'measure',
        capacity:'capacity',
        frequency:'frequency',
        method:'method',
      },
      //控制计划的大表,Excel上传用到
      controlPlanDataExcel: [
        {
          // 主键ID（对应数据库id字段）
          id: null,

          // 零件/过程编号（多语言字段组）
          process_number: '',       // 中文
          process_number_english: '', // 英文
          process_number_russian: '', // 俄文

          // 机器/夹具/装置/工装（多语言字段组）
          device: '',               // 中文
          device_english: '',       // 英文
          device_russian: '',       // 俄文

          // 过程名称/操作描述（多语言字段组）
          operation: '',            // 中文
          operation_english: '',    // 英文
          operation_russian: '',    // 俄文

          // 编号字段
          number_order: '',         // 记录编号

          // 产品相关字段（多语言字段组）
          product: '',              // 中文
          product_english: '',      // 英文
          product_russian: '',      // 俄文

          // 过程相关字段（多语言字段组）
          process_use: '',          // 中文
          process_use_english: '',  // 英文
          process_use_russian: '',  // 俄文

          // 特殊特性分类
          characteristic: '',       // 特殊特性类型标识

          // 规范公差相关字段（多语言字段组）
          specification: '',        // 中文
          specification_english: '',// 英文
          specification_russian: '',// 俄文

          // 测量技术相关字段（多语言字段组）
          measure: '',              // 中文
          measure_english: '',      // 英文
          measure_russian: '',      // 俄文

          // 容量相关字段（多语言字段组）
          capacity: '',             // 中文
          capacity_english: '',     // 英文
          capacity_russian: '',     // 俄文

          // 频率相关字段（多语言字段组）
          frequency: '',            // 中文
          frequency_english: '',    // 英文
          frequency_russian: '',    // 俄文

          // 控制方法相关字段（多语言字段组）
          method: '',               // 中文
          method_english: '',       // 英文
          method_russian: '',       // 俄文

          // 责任部门相关字段（多语言字段组）
          department: '',           // 中文
          department_english: '',   // 英文
          department_russian: '',   // 俄文

          // 反应计划标识（0-未处理 1-已处理）
          reaction: 0,

          // 产品图号
          drawing: '',

          // 工序号（数字类型）
          op: 0,

          // 车间名称相关字段（多语言字段组）
          workshop: '',             // 中文
          workshop_english: '',     // 英文
          workshop_russian: '',     // 俄文

          // 记录顺序号（数字排序用）
          order_number: 0,

          // 自定义字段（非直接映射）

          sys_deleted:0,            //删除标记位

          // 人员相关字段
          creator: '',              // 创建人
          sys_update_user: '',      // 最后更新人
          sys_audit_user: '',       // 审核人
        }
      ],
      //部门选择器
      //车间/科室的选项
      workshopOptions:[
        {label:'机加/Machining Workshop/Обработки линия', value:'机加/Machining Workshop/Обработки линия'},
        {label:'装配/Assembly Workshop/Сборочная линия', value:'装配/Assembly Workshop/Сборочная линия'},
        {label:'产技/Product Technology/Tехнологий продукции', value:'产技/Product Technology/Tехнологий продукции'},
        {label:'品管/Quality Management/Управления качеством', value:'品管/Quality Management/Управления качеством'},
        {label:'制技/Manufacture Tech/Tехнологии производства', value:'制技/Manufacture Tech/Tехнологии производства'},
        {label:'物流/Logistics Department/Отдел логистики', value:'物流/Logistics Department/Отдел логистики'},
        {label:'设备/Maintenance Utility/Oбслуживания оборудования', value:'设备/Maintenance Utility/Oбслуживания оборудования'},
      ],


      //控制弹窗的抬头显示
      titleMessage:'提示',
      //控制弹窗的文字显示
      dialogText:'',
      //控制EXCEL批量导入控制计划的弹窗
      controlPlanExcelAddDialog:false,
      //控制修改控制计划弹窗
      controlPlanEditDialog:false,
      //控制计划内容编辑的弹窗
      controlPlanDialog:false,
      //控制删除数据的弹窗,默认关闭
      deleteDataDialog:false,
    }
  },
  methods: {
    //通用：得到UUID的id数据
    generateUUIDv4() {
      const bytes = new Uint8Array(16);
      crypto.getRandomValues(bytes);

      // 设置版本位（第6字节的高4位为0100）
      bytes[6] = (bytes[6] & 0x0f) | 0x40;
      // 设置变体位（第8字节的高2位为10）
      bytes[8] = (bytes[8] & 0x3f) | 0x80;

      // 转换为32字符十六进制字符串
      return Array.from(bytes, byte => {
        return byte.toString(16).padStart(2, '0');
      }).join('');
    },
    //通用：误关闭弹窗的函数
    // eslint-disable-next-line no-unused-vars
    handleClose(done) {
      this.$confirm('确认关闭？')
          // eslint-disable-next-line no-unused-vars
          .then(_ => {
            done();
          })
          // eslint-disable-next-line no-unused-vars
          .catch(_ => {});
    },
    //退出登录
    logOut(){
      localStorage.removeItem('u_token');
      localStorage.removeItem('userName')
      this.$router.push('UserLogin')
    },
    //查询用户信息的函数
    inquiry() {
      //输入用户编号，向后端查询信息
      const useId = localStorage.getItem('userName').replace(/"/g, '');
      this.$request.post('/useQueryPower', {
        queryFiledName: 'controlPlanNew',
        userId: useId,
      }).then(result => {
        if (result.code === 401) {
          this.$router.push('UserLogin')
          alert("您未登录，请登录")
        } else {
          this.useName = result.data.name
          this.usePower = result.data.controlPlanNew
          this.useId = useId
        }
      })
    },
    //选择不同语言做的反应
    languageSelect(language){
      this.languageS=language
      this.componentKey = !this.componentKey; // 修改 key 强制重新渲染
      if (language==='chinese'){
        this.treeControlPlan=[
            {
          label: '装配车间',
          children: [
            {
              label: '1000100XEB05',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120预留工位'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP155预留工位'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP245'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275预留工位'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330预留工位'
                },
                {
                  label: 'OP340预留工位'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP375'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'HL35'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG80'
                }
              ]
            },
            {
              label: '1000100XEB75',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG130'
                }
              ]
            },
            {
              label: '1000100XEN19',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390-1'
                },
                {
                  label: 'OP390-2'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG130'
                }
              ]
            },
            {
              label: '1000100XEN38',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP01'
                },
                {
                  label: 'OP02'
                },
                {
                  label: 'OP03'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330'
                },
                {
                  label: 'OP340'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG130'
                }
              ]
            }
          ]
        },
            {
            label: '机加车间',
            children: [
              {
                label: '1002100XEB75',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30-1'
                  },
                  {
                    label: 'OP30-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP50-1'
                  },
                  {
                    label: 'OP50-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP75'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90'
                  },
                  {
                    label: 'OP100'
                  },
                  {
                    label: 'OP110-1'
                  },
                  {
                    label: 'OP110-2'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP135'
                  },
                  {
                    label: 'OP140'
                  },
                  {
                    label: 'OP150'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                ]
              },
              {
                label: '1003100AEB75',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30A-1'
                  },
                  {
                    label: 'OP30A-2'
                  },
                  {
                    label: 'OP30B-1'
                  },
                  {
                    label: 'OP30B-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90-1'
                  },
                  {
                    label: 'OP90-2'
                  },
                  {
                    label: 'OP100-1'
                  },
                  {
                    label: 'OP100-2'
                  },
                  {
                    label: 'OP105'
                  },
                  {
                    label: 'OP110'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP140-1'
                  },
                  {
                    label: 'OP140-2'
                  },
                  {
                    label: 'OP150-1'
                  },
                  {
                    label: 'OP150-2'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                  {
                    label: 'OP180'
                  },
                  {
                    label: 'OP190'
                  },
                  {
                    label: 'OP200'
                  },
                ]
              },
              {
                label: '1002100XEB05',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30-1'
                  },
                  {
                    label: 'OP30-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP50-1'
                  },
                  {
                    label: 'OP50-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP75'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90'
                  },
                  {
                    label: 'OP100'
                  },
                  {
                    label: 'OP110-1'
                  },
                  {
                    label: 'OP110-2'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP135'
                  },
                  {
                    label: 'OP140'
                  },
                  {
                    label: 'OP150'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                ]
              },
              {
                label: '1003100AEB05',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30A-1'
                  },
                  {
                    label: 'OP30A-2'
                  },
                  {
                    label: 'OP30B-1'
                  },
                  {
                    label: 'OP30B-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90-1'
                  },
                  {
                    label: 'OP90-2'
                  },
                  {
                    label: 'OP100-1'
                  },
                  {
                    label: 'OP100-2'
                  },
                  {
                    label: 'OP105'
                  },
                  {
                    label: 'OP110'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP140-1'
                  },
                  {
                    label: 'OP140-2'
                  },
                  {
                    label: 'OP150-1'
                  },
                  {
                    label: 'OP150-2'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                  {
                    label: 'OP180'
                  },
                  {
                    label: 'OP190'
                  },
                  {
                    label: 'OP200'
                  },
                ]
              }
            ]
          }
        ]
        this.firstTree=this.treeControlPlan
        this.main.qualityManagementSystem='俄动力质量管理系统'
        this.main.controlPlanManagement='控制计划管理'
        this.main.filter='输入关键字进行过滤'

        this.pageVal.controlPlan='控制计划'
        this.pageVal.workshop='车间：'
        this.pageVal.product='产品：'
        this.pageVal.op='工序：'
        this.pageVal.excel='EXCEL上传'
        this.pageVal.processName='过程名称/操作描述'
        this.pageVal.device='机器、装置、夹具、工装'
        this.pageVal.characteristic='特性'
        this.pageVal.number='编号'
        this.pageVal.product1='产品'
        this.pageVal.process='过程'
        this.pageVal.characteristicClassification='特殊特性分类'
        this.pageVal.method='方法'
        this.pageVal.tolerance='产品/过程规范/公差'
        this.pageVal.measure='评价/测量技术'
        this.pageVal.capacity='容量'
        this.pageVal.frequency='频率'
        this.pageVal.controlMethod='控制方法'
        this.pageVal.department='责任部门'
        this.pageVal.reaction='反应计划'
        this.pageVal.edit='编辑'
        this.pageVal.delete='删除'
        this.pageVal.insertDownwards='向下插入'
        this.pageVal.insertUpwards='向上插入'
      }
      else if (language==='english'){
        this.treeControlPlan=[
            {
          label: 'Assembly Workshop',
          children: [
            {
              label: '1000100XEB05',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120预留工位'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP155预留工位'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP245'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275预留工位'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330预留工位'
                },
                {
                  label: 'OP340预留工位'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP375'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'HL35'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG80'
                }
              ]
            }
          ]
        },
            {
            label: 'Machining Workshop',
            children: [
              {
                label: '1002100XEB75',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30-1'
                  },
                  {
                    label: 'OP30-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP50-1'
                  },
                  {
                    label: 'OP50-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP75'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90'
                  },
                  {
                    label: 'OP100'
                  },
                  {
                    label: 'OP110-1'
                  },
                  {
                    label: 'OP110-2'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP135'
                  },
                  {
                    label: 'OP140'
                  },
                  {
                    label: 'OP150'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                ]
              },
              {
                label: '1003100AEB75',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30A-1'
                  },
                  {
                    label: 'OP30A-2'
                  },
                  {
                    label: 'OP30B-1'
                  },
                  {
                    label: 'OP30B-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90-1'
                  },
                  {
                    label: 'OP90-2'
                  },
                  {
                    label: 'OP100-1'
                  },
                  {
                    label: 'OP100-2'
                  },
                  {
                    label: 'OP105'
                  },
                  {
                    label: 'OP110'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP140-1'
                  },
                  {
                    label: 'OP140-2'
                  },
                  {
                    label: 'OP150-1'
                  },
                  {
                    label: 'OP150-2'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                  {
                    label: 'OP180'
                  },
                  {
                    label: 'OP190'
                  },
                  {
                    label: 'OP200'
                  },
                ]
              },
              {
                label: '1002100XEB05',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30-1'
                  },
                  {
                    label: 'OP30-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP50-1'
                  },
                  {
                    label: 'OP50-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP75'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90'
                  },
                  {
                    label: 'OP100'
                  },
                  {
                    label: 'OP110-1'
                  },
                  {
                    label: 'OP110-2'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP135'
                  },
                  {
                    label: 'OP140'
                  },
                  {
                    label: 'OP150'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                ]
              },
              {
                label: '1003100AEB05',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30A-1'
                  },
                  {
                    label: 'OP30A-2'
                  },
                  {
                    label: 'OP30B-1'
                  },
                  {
                    label: 'OP30B-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90-1'
                  },
                  {
                    label: 'OP90-2'
                  },
                  {
                    label: 'OP100-1'
                  },
                  {
                    label: 'OP100-2'
                  },
                  {
                    label: 'OP105'
                  },
                  {
                    label: 'OP110'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP140-1'
                  },
                  {
                    label: 'OP140-2'
                  },
                  {
                    label: 'OP150-1'
                  },
                  {
                    label: 'OP150-2'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                  {
                    label: 'OP180'
                  },
                  {
                    label: 'OP190'
                  },
                  {
                    label: 'OP200'
                  },
                ]
              }
            ]
          }
        ]
        this.main.qualityManagementSystem='Quality Management System'
        this.main.controlPlanManagement='Control Plan Management'
        this.main.filter='Keywords for filtering'

        this.pageVal.controlPlan='Control Plan'
        this.pageVal.workshop='Workshop:'
        this.pageVal.product='Product:'
        this.pageVal.op='OP:'
        this.pageVal.excel='EXCEL Upload'
        this.pageVal.processName='Process Name/ Operation Description'
        this.pageVal.device='Machine、Device、Fixture、Tooling'
        this.pageVal.characteristic='Characteristic'
        this.pageVal.number='Number'
        this.pageVal.product1='Product'
        this.pageVal.process='Process'
        this.pageVal.characteristicClassification='Characteristic Classification'
        this.pageVal.method='Method'
        this.pageVal.tolerance='Product/ Process Specification/ Tolerance'
        this.pageVal.measure='Evaluation/ Measurement Technique'
        this.pageVal.capacity='Capacity'
        this.pageVal.frequency='Frequency'
        this.pageVal.controlMethod='Control Method'
        this.pageVal.department='Department'
        this.pageVal.reaction='Reaction Plan'
        this.pageVal.edit='Edit'
        this.pageVal.delete='Delete'
        this.pageVal.insertDownwards='Insert Downwards'
        this.pageVal.insertUpwards='Insert Upwards'
      }
      else if (language==='russian'){
        this.treeControlPlan=[
            {
          label: 'Сборочная линия',
          children: [
            {
              label: '1000100XEB05',
              children: [
                {
                  label: 'OP00'
                },
                {
                  label: 'OP10'
                },
                {
                  label: 'OP20'
                },
                {
                  label: 'OP30-1'
                },
                {
                  label: 'OP30'
                },
                {
                  label: 'OP40'
                },
                {
                  label: 'OP50'
                },
                {
                  label: 'OP60'
                },
                {
                  label: 'OP70'
                },
                {
                  label: 'OP80'
                },
                {
                  label: 'OP90'
                },
                {
                  label: 'OP100'
                },
                {
                  label: 'OP105'
                },
                {
                  label: 'OP120预留工位'
                },
                {
                  label: 'OP130'
                },
                {
                  label: 'OP140'
                },
                {
                  label: 'OP150'
                },
                {
                  label: 'OP155预留工位'
                },
                {
                  label: 'OP160'
                },
                {
                  label: 'OP170'
                },
                {
                  label: 'OP180'
                },
                {
                  label: 'OP190'
                },
                {
                  label: 'OP200'
                },
                {
                  label: 'OP210'
                },
                {
                  label: 'OP220'
                },
                {
                  label: 'OP230'
                },
                {
                  label: 'OP240-1'
                },
                {
                  label: 'OP240'
                },
                {
                  label: 'OP245'
                },
                {
                  label: 'OP250'
                },
                {
                  label: 'OP260'
                },
                {
                  label: 'OP270'
                },
                {
                  label: 'OP275预留工位'
                },
                {
                  label: 'OP280-1'
                },
                {
                  label: 'OP280-2'
                },
                {
                  label: 'OP280-3'
                },
                {
                  label: 'OP280-4'
                },
                {
                  label: 'OP280-5'
                },
                {
                  label: 'OP290'
                },
                {
                  label: 'OP300'
                },
                {
                  label: 'OP310'
                },
                {
                  label: 'OP320'
                },
                {
                  label: 'OP330预留工位'
                },
                {
                  label: 'OP340预留工位'
                },
                {
                  label: 'OP350-1'
                },
                {
                  label: 'OP350'
                },
                {
                  label: 'OP360'
                },
                {
                  label: 'OP370'
                },
                {
                  label: 'OP375'
                },
                {
                  label: 'OP380'
                },
                {
                  label: 'OP390'
                },
                {
                  label: 'OP400'
                },
                {
                  label: 'OP410-1'
                },
                {
                  label: 'OP410'
                },
                {
                  label: 'OP420'
                },
                {
                  label: 'OP430'
                },
                {
                  label: 'OP440-1'
                },
                {
                  label: 'OP440'
                },
                {
                  label: 'OP450'
                },
                {
                  label: 'OP460'
                },
                {
                  label: 'OP470'
                },
                {
                  label: 'OP480'
                },
                {
                  label: 'OP490'
                },
                {
                  label: 'OP500'
                },
                {
                  label: 'OP510'
                },
                {
                  label: 'OP520'
                },
                {
                  label: 'OP530'
                },
                {
                  label: 'HL10'
                },
                {
                  label: 'HL20'
                },
                {
                  label: 'HL30'
                },
                {
                  label: 'HL35'
                },
                {
                  label: 'GG10'
                },
                {
                  label: 'GG20'
                },
                {
                  label: 'GG30'
                },
                {
                  label: 'GG40'
                },
                {
                  label: 'GG45'
                },
                {
                  label: 'GG50'
                },
                {
                  label: 'GG80'
                }
              ]
            }
          ]
        },
            {
            label: 'Обработки линия',
            children: [
              {
                label: '1002100XEB75',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30-1'
                  },
                  {
                    label: 'OP30-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP50-1'
                  },
                  {
                    label: 'OP50-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP75'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90'
                  },
                  {
                    label: 'OP100'
                  },
                  {
                    label: 'OP110-1'
                  },
                  {
                    label: 'OP110-2'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP135'
                  },
                  {
                    label: 'OP140'
                  },
                  {
                    label: 'OP150'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                ]
              },
              {
                label: '1003100AEB75',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30A-1'
                  },
                  {
                    label: 'OP30A-2'
                  },
                  {
                    label: 'OP30B-1'
                  },
                  {
                    label: 'OP30B-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90-1'
                  },
                  {
                    label: 'OP90-2'
                  },
                  {
                    label: 'OP100-1'
                  },
                  {
                    label: 'OP100-2'
                  },
                  {
                    label: 'OP105'
                  },
                  {
                    label: 'OP110'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP140-1'
                  },
                  {
                    label: 'OP140-2'
                  },
                  {
                    label: 'OP150-1'
                  },
                  {
                    label: 'OP150-2'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                  {
                    label: 'OP180'
                  },
                  {
                    label: 'OP190'
                  },
                  {
                    label: 'OP200'
                  },
                ]
              },
              {
                label: '1002100XEB05',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30-1'
                  },
                  {
                    label: 'OP30-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP50-1'
                  },
                  {
                    label: 'OP50-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP75'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90'
                  },
                  {
                    label: 'OP100'
                  },
                  {
                    label: 'OP110-1'
                  },
                  {
                    label: 'OP110-2'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP135'
                  },
                  {
                    label: 'OP140'
                  },
                  {
                    label: 'OP150'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                ]
              },
              {
                label: '1003100AEB05',
                children: [
                  {
                    label: 'OP05'
                  },
                  {
                    label: 'OP10-1'
                  },
                  {
                    label: 'OP10-2'
                  },
                  {
                    label: 'OP20-1'
                  },
                  {
                    label: 'OP20-2'
                  },
                  {
                    label: 'OP30A-1'
                  },
                  {
                    label: 'OP30A-2'
                  },
                  {
                    label: 'OP30B-1'
                  },
                  {
                    label: 'OP30B-2'
                  },
                  {
                    label: 'OP40-1'
                  },
                  {
                    label: 'OP40-2'
                  },
                  {
                    label: 'OP60'
                  },
                  {
                    label: 'OP70'
                  },
                  {
                    label: 'OP80'
                  },
                  {
                    label: 'OP90-1'
                  },
                  {
                    label: 'OP90-2'
                  },
                  {
                    label: 'OP100-1'
                  },
                  {
                    label: 'OP100-2'
                  },
                  {
                    label: 'OP105'
                  },
                  {
                    label: 'OP110'
                  },
                  {
                    label: 'OP120'
                  },
                  {
                    label: 'OP130'
                  },
                  {
                    label: 'OP140-1'
                  },
                  {
                    label: 'OP140-2'
                  },
                  {
                    label: 'OP150-1'
                  },
                  {
                    label: 'OP150-2'
                  },
                  {
                    label: 'OP160'
                  },
                  {
                    label: 'OP170'
                  },
                  {
                    label: 'OP180'
                  },
                  {
                    label: 'OP190'
                  },
                  {
                    label: 'OP200'
                  },
                ]
              }
            ]
          }
        ]
        this.main.qualityManagementSystem='Система управления качеством'
        this.main.controlPlanManagement='Управление планом контроля'
        this.main.filter='Фильтр'

        this.pageVal.controlPlan='План контроля'
        this.pageVal.workshop='Цех:'
        this.pageVal.product='Продукт:'
        this.pageVal.op='Операция:'
        this.pageVal.excel='Загрузка EXCEL'
        this.pageVal.processName='Имя процесса/ Описание операции'
        this.pageVal.device='Машина、Устройство、Инструмент'
        this.pageVal.characteristic='Характеристика'
        this.pageVal.number='Номер'
        this.pageVal.product1='Продукт'
        this.pageVal.process='Процесс'
        this.pageVal.characteristicClassification='Характеристическая классификация'
        this.pageVal.method='Метод'
        this.pageVal.tolerance='Продукт/ Спецификация процесса/ Толерантность'
        this.pageVal.measure='Оценка/ Техника измерения'
        this.pageVal.capacity='Емкость'
        this.pageVal.frequency='Частота'
        this.pageVal.controlMethod='Метод контроля'
        this.pageVal.department='Департамент'
        this.pageVal.reaction='План реакции'
        this.pageVal.edit='Редактировать'
        this.pageVal.delete='Удалить'
        this.pageVal.insertDownwards='Вставить вниз'
        this.pageVal.insertUpwards='Вставить вверх'
      }
      // 更新 firstTree
      this.firstTree = this.treeControlPlan[0]?.label || '';
    },
    //点击分页标签
    handleClick(tab, event) {
      console.log(tab, event);
    },
    //单击控制计划的树形导航结构
    treeClick(data,node){
      if (node.level===3){
        this.thirdTree=data.label
        this.secondTree=node.parent.label
        this.firstTree=node.parent.parent.label
        let workshop=''
        if (this.firstTree==='装配车间' || this.firstTree==='Assembly Workshop' ||this.firstTree==='Сборочная линия'){
          workshop='装配/Assembly Workshop/Сборочная линия'
        }
        else if (this.firstTree==='机加车间' || this.firstTree==='Machining Workshop' ||this.firstTree==='Обработки линия'){
          workshop='机加/Machining Workshop/Обработки линия'
        }
        //查询出新的控制计划
        this.queryThreeFieldControlPlan('workshop',workshop,'drawing',this.secondTree, 'op',this.thirdTree).then(data=>{
          this.controlPlanData=data
        })
      }
    },
    //导航筛选的函数
    filterNode(value, data) {
      if (!value) return true;
      return data.label.indexOf(value) !== -1;
    },

    controlPlanDialogShow(scope,doe) {
      this.controlPlanDoe=doe
      this.controlPlanScope=scope
      if (this.thirdTree===''){
        alert("您未选择任何产品及工序，请选择后进行操作")
        return
      }
      //返回用户选择的类型
      // if (scope!==null){
      //   //返回用户选择数据的index。
      //   this.selectedIndexUse=scope.$index
      // }
      // else {
      //   this.selectedIndexUse=-1
      // }
      //点击“编辑”中的“编辑”按钮，弹窗展现内容
      if (doe===1){
        //给表单赋值
        this.controlPlanForm=_.cloneDeep(scope.row)
        this.titleMessage="提示：您选择的操作为：编辑\n 将修改以下数据"
        this.controlPlanDialog=true
      }
      else if (doe===3 ||doe===4){
        //打开一个空的弹窗,是向下或者向上插入
        this.controlPlanForm= {
          //唯一标识，低代码的主键
          id:'',
          //创建时间
          create_time:'',
          //更新时间
          update_time:'',
          //创建人
          creator:'',
          //流程状态
          process_status:'',
          //更新人
          sys_update_user:'',
          //审核人
          sys_audit_user:'',
          //审核时间
          sys_audit_time:'',
          //逻辑删除
          sys_deleted:0,
          //零件/过程编号
          process_number: '',
          process_number_english:'',
          process_number_russian:'',
          //机器、夹具、装置、工装
          device: '',
          device_english:'',
          device_russian:'',
          //过程名称/操作描述
          operation: '',
          operation_english:'',
          operation_russian:'',
          //编号
          number_order: '',
          //产品
          product: '',
          product_english:'',
          product_russian:'',
          //过程
          process_use: '',
          process_use_english:'',
          process_use_russian:'',
          //特殊特性分类
          characteristic:'',
          //产品、过程规范、公差
          specification: '',
          specification_english:'',
          specification_russian:'',
          //评价、测量技术
          measure: '',
          measure_english:'',
          measure_russian:'',
          //容量
          capacity: '',
          capacity_english:'',
          capacity_russian:'',
          //频率
          frequency: '',
          frequency_english:'',
          frequency_russian:'',
          //控制方法
          method: '',
          method_english:'',
          method_russian:'',
          //责任部门
          department: '',
          department_english:'',
          department_russian:'',
          //反应计划
          reaction:'',
          //产品图号
          drawing: '',
          //工序号
          op: 0,
          //车间名称
          workshop:'',
          //记录顺序号，进行排序用
          order_number:0,
        }
        //把固定的字段赋值给controlPlanForm（车间名称，图号，工序号）
        this.controlPlanForm.workshop=this.controlPlanData[0].workshop
        this.controlPlanForm.drawing=this.controlPlanData[0].drawing
        this.controlPlanForm.op=this.controlPlanData[0].op
        this.controlPlanForm.id="new"
        if (doe===3){
          this.titleMessage="提示：您选择的是向下插入行\n 将修改以下数据"
        }
        else {
          this.titleMessage="提示：您选择的是向上插入行\n 将修改以下数据"
        }
        this.controlPlanDialog=true
      }
    },
    controlPlanDialogOk() {
      //当编辑一行时
      if(this.controlPlanDoe===1){

        this.$request.post('/editControlPlanControlPlanNew',this.controlPlanForm).then(result=>{
          //如果未接收到数据，执行用户登录界面
          if (result.code===401){
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }
          //如果成功接收到数据，在控制台打印数据并提示编辑成功
          else{
            if (this.languageS==='chinese'){
              this.$message.success('编辑成功')
            }
            else if (this.languageS==='english'){
              this.$message.success('Edit successfully')
            }
            else if (this.languageS==='russian'){
              this.$message.success('Редактировать успешно')
            }
            //修改大表数据
            this.controlPlanData.splice(this.controlPlanScope.$index,1,this.controlPlanForm)

            //关闭窗口
            this.controlPlanDialog=false
          }
        })
      }
      else if(this.controlPlanDoe===3 || this.controlPlanDoe===4){
        //第一步：组合数据
        let controlPlanDataTemp=_.cloneDeep(this.controlPlanData)
        //3是向下插入
        if (this.controlPlanDoe===3){
          controlPlanDataTemp.splice(this.controlPlanScope.$index+1,0,this.controlPlanForm)
        }
        //4是向上插入
        else if (this.controlPlanDoe===4){
          controlPlanDataTemp.splice(this.controlPlanScope.$index,0,this.controlPlanForm)
        }
        //第二步：更改顺序号
        for (let i = 0; i < controlPlanDataTemp.length; i++) {
          controlPlanDataTemp[i].order_number=i+1
        }
        console.log(this.controlPlanData)
        console.log(controlPlanDataTemp)
        this.$request.post('/insertControlPlanControlPlanNew',controlPlanDataTemp).then(result=>{
          //如果未接收到数据，执行用户登录界面
          if (result.code===401){
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }
          //如果成功接收到数据，在控制台打印数据并提示编辑成功
          else{
            if (this.languageS==='chinese'){
              this.$message.success('插入成功')
            }
            else if (this.languageS==='english'){
              this.$message.success('Insert successfully')
            }
            else if (this.languageS==='russian'){
              this.$message.success('Успешно вставить')
            }
            this.controlPlanData=result.data
            //关闭窗口
            this.controlPlanDialog=false
          }
        })
      }
    },

    //通用：点击删除按钮时的弹窗
    deleteDataShow(doe,scope){
      this.deleteDataDoe=doe
      if (doe==='deleteControlPlanOneRow'){
        this.controlPlanScope=scope
        this.controlPlanForm=_.cloneDeep(scope.row)
        if (this.languageS==="chinese"){
          this.titleMessage='删除本行数据'
        }
        else if (this.languageS==="english"){
          this.titleMessage='Delete this row'
        }
        else if (this.languageS==="russian"){
          this.titleMessage='Удалить эту строку'
        }
        this.deleteDataDialog=true
      }
    },
    //通用：删除某一行数据
    deleteDataOk(){
      if (this.deleteDataDoe==='deleteControlPlanOneRow'){
        //设置删除位的值为1
        this.controlPlanForm.sys_deleted=1
        this.$request.post('/editControlPlanControlPlanNew',this.controlPlanForm).then(result=>{
          //如果未接收到数据，执行用户登录界面
          if (result.code===401){
            this.$router.push('UserLogin')
            alert("您未登录，请登录")
          }
          //如果成功接收到数据，在控制台打印数据并提示编辑成功
          else{
            if (this.languageS==='chinese'){
              this.$message.success('删除成功')
            }
            else if (this.languageS==='english'){
              this.$message.success('Delete successfully')
            }
            else if (this.languageS==='russian'){
              this.$message.success('Успешно удалить')
            }
            //修改大表数据
            this.controlPlanData.splice(this.controlPlanScope.$index,1)
            //关闭窗口
            this.deleteDataDialog=false
          }
        })
      }
    },

    //上传EXCEL文件的函数
    // eslint-disable-next-line no-unused-vars
    handleUploadSuccess(file) {
      // 校验文件对象有效性
      if (!file?.raw?.type?.includes('application/vnd.openxmlformats-officedocument.spreadsheetml.sheet')) {
        console.error('❌ 文件格式不正确，请上传.xlsx文件');
        return;
      }
      const fileReader = new FileReader();
      // 添加完整的事件监听
      fileReader.onload = (e) => {
        try {
          // 校验读取结果
          if (!e.target?.result?.byteLength) {
            console.error('❌ 文件读取内容为空');
            return;
          }
          // 使用更健壮的读取方式
          const arrayBuffer = e.target.result;
          const workbook = XLSX.read(arrayBuffer, { type: 'array', cellDates: true });
          // 校验工作簿内容
          if (!workbook.SheetNames?.length) {
            console.error('❌ Excel文件不包含任何工作表');
            return;
          }
          // 获取第一个工作表
          const worksheet = workbook.Sheets[workbook.SheetNames[0]];

          // 校验工作表内容
          if (!Object.keys(worksheet).length) {
            console.error('❌ 工作表内容为空');
            return;
          }
          // 转换为JSON（添加空白行处理）
          const jsonData = XLSX.utils.sheet_to_json(worksheet, {
            header: 1,
            blankrows: false,
            defval: ''
          });

          // 校验解析结果
          if (!jsonData?.length) {
            console.error('❌ 解析结果为空，请检查文件内容');
            return;
          }
          //数据校验1：看用户是否选择了某一个工序
          if (this.thirdTree==='' || this.secondTree==='' || this.firstTree===''){
            this.$message.success('您未选择工序，请先选择')
            return;
          }
          //数据校验2：校验最后一行是不是有备注
          for (let i = 0; i < jsonData[jsonData.length-1].length; i++) {
            const cellValue = String(jsonData[jsonData.length-1][i] || ''); // 转为字符串，空值转为空字符串
            if (cellValue.includes('备注')){
              this.$message.error('文件最后一行有备注，已删除')
              jsonData.splice(jsonData.length-1,1)
            }
          }
          //数据校验3：检验是不首行的过程或产品为空
          for (let i = 3; i <8; i++) {
            if (jsonData[9][i]==='' || jsonData[9][i]===undefined || jsonData[9][i]===null){
              this.$message.error('首行“过程名称／操作描述”、“机器、装置夹具、工装”为空，填写后再尝试')
              return;
            }
          }
          //数据校验4：校验用户选择的文件是否和选择的工序对应,信息显示在窗口中

          this.dialogText='您要插入的车间为：'+this.firstTree+'；产品为：'+this.secondTree+'；工序为：'+this.thirdTree
          // 在这里添加业务逻辑
          this.processExcelDataControlPlan(jsonData);
          //打开弹窗
          this.controlPlanExcelAddDialog=true

        } catch (error) {
          console.error('🚨 解析过程中发生错误:', error);
        }
      };
      fileReader.onerror = (error) => {
        console.error('❌ 文件读取失败:', error);
      };

      // 显式指定读取格式
      fileReader.readAsArrayBuffer(file.raw);
      // 清空已选文件列表
      this.$refs.excelUpload.clearFiles();
    },
    // 对控制计划上传的数据进行处理，并且打开确定弹窗，是直接插入
    controlPlanExcelAddOk(){
      //向后端传递数据
      this.$request.post('/insertMultiLineControlPlanControlPlanNew',this.controlPlanDataExcel).then(result=>{
            if (result.code === 401) {
              this.$router.push('UserLogin')
              alert("您未登录，请登录")
            }
            else {
              this.controlPlanData=this.controlPlanDataExcel
              this.$message('插入成功')

              this.controlPlanExcelAddDialog=false
            }
      })
    },
    //对控制计划上传的数据进行处理，是删除原来所有，然后再进行插入
    controlPlanExcelCoverAddOk(){
      //向后端传递数据
      //先去把原来所有的删除掉。
      this.$request.post('/insertMultiLineCoverControlPlanControlPlanNew',this.controlPlanDataExcel).then(result=>{
        if (result.code === 401) {
          this.$router.push('UserLogin')
          alert("您未登录，请登录")
        }
        else {
          this.controlPlanData=this.controlPlanDataExcel
          this.$message('插入成功')

          this.controlPlanExcelAddDialog=false
        }
      })
    },
    //辅助函数：处理接收到的EXCEL的文件，组合成控制计划的项目
    processExcelDataControlPlan(data) {
      // 在这里添加您的业务逻辑
      //进行循环对应
      this.controlPlanDataExcel=[]
      //第一遍赋值
      for (let i = 9; i < data.length; i++) {
        //获得唯一的ID
        const id=this.generateUUIDv4()
        //分解部门
        let department=''                   // 中文（新增字段，原data[32]未赋值）
        let department_english=''           // 英文（新增字段）
        let department_russian=''
        let workshop=''
        if (this.firstTree==='装配车间' || this.firstTree==='Assembly Workshop' || this.firstTree==='Сборочная линия'){
          workshop='装配/Assembly Workshop/Сборочная линия'
        }
        else if (this.firstTree==='机加车间' || this.firstTree==='Machining Workshop' || this.firstTree==='Обработки линия'){
          workshop='机加/Machining Workshop/Обработки линия'
        }

         if (data[i][32].includes('装配') || data[i][32].includes('装试')){
           department='装配'
           department_english='Assembly Workshop'
           department_russian='Сборочная линия'
        }
         else if (data[i][32].includes('品技') || data[i][32].includes('产技') || data[i][32].includes('品质技术')){
           department='产技'
           department_english='Product Technology'
           department_russian='Технология продукции'
         }
         else if (data[i][32].includes('物流')){
           department='物流'
           department_english='Logistics Department'
           department_russian='Отдел логистики'
         }
         else if (data[i][32].includes('品质管理')){
           department='品管'
           department_english='Quality Management'
           department_russian='Управления качеством'
         }
         //整合容量
        let capacity=''
        let capacity_english=''       // 英文（原capacityEnglish）
        let capacity_russian=''
        if (String(data[i][23])==='1'){
          capacity='100%'
          capacity_english='100%'
          capacity_russian='100%'
        }
        else {
          capacity=String(data[i][23])
          capacity_english=String(data[i][24])
          capacity_russian=String(data[i][25])
        }
        this.controlPlanDataExcel.push({
          // 主键ID（修改点：字段名改为下划线格式）
          id: id,

          // 零件/过程编号（多语言字段组）
          process_number: data[i][0],          // 中文（原processNumber）
          process_number_english: data[i][1],  // 英文（原processNumberEnglish）
          process_number_russian: data[i][2],  // 俄文（原processNumberRussian）

          // 机器/夹具/装置/工装（多语言字段组）
          device: data[i][6],                  // 中文（原device）
          device_english: data[i][7],          // 英文（原deviceEnglish）
          device_russian: data[i][8],          // 俄文（原deviceRussian）

          // 过程名称/操作描述（多语言字段组）
          operation: data[i][3],               // 中文（原operation）
          operation_english: data[i][4],       // 英文（原operationEnglish）
          operation_russian: data[i][5],       // 俄文（原operationRussian）

          // 编号字段
          number_order: data[i][9],            // 记录编号（原numberOrder）

          // 产品相关字段（多语言字段组）
          product: data[i][10],                // 中文（原product）
          product_english: data[i][11],        // 英文（原productEnglish）
          product_russian: data[i][12],        // 俄文（原productRussian）

          // 过程相关字段（多语言字段组）
          process_use: data[i][13],            // 中文（原processUse）
          process_use_english: data[i][14],    // 英文（原processUseEnglish）
          process_use_russian: data[i][15],    // 俄文（原processUseRussian）

          // 特殊特性分类
          characteristic: data[i][16],         // 特殊特性类型标识（保持不变）

          // 规范公差相关字段（多语言字段组）
          specification: data[i][17],          // 中文（原specification）
          specification_english: data[i][18],  // 英文（原specificationEnglish）
          specification_russian: data[i][19],  // 俄文（原specificationRussian）

          // 测量技术相关字段（多语言字段组）
          measure: data[i][20],                // 中文（原measure）
          measure_english: data[i][21],        // 英文（原measureEnglish）
          measure_russian: data[i][22],        // 俄文（原measureRussian）

          // 容量相关字段（多语言字段组）
          capacity: capacity,               // 中文（原capacity）
          capacity_english: capacity_english,       // 英文（原capacityEnglish）
          capacity_russian: capacity_russian,       // 俄文（原capacityRussian）

          // 频率相关字段（多语言字段组）
          frequency: String(data[i][26]),   // 中文（原frequency）
          frequency_english: String(data[i][27]), // 英文（原frequencyEnglish）
          frequency_russian: String(data[i][28]), // 俄文（原frequencyRussian）

          // 控制方法相关字段（多语言字段组）
          method: data[i][29],                 // 中文（原method）
          method_english: data[i][30],         // 英文（原methodEnglish）
          method_russian: data[i][31],         // 俄文（原methodRussian）

          // 责任部门相关字段（多语言字段组）
          department: department,                   // 中文（新增字段，原data[32]未赋值）
          department_english: department_english,           // 英文（新增字段）
          department_russian: department_russian,           // 俄文（新增字段）

          // 反应计划（修改点：字段名改为下划线格式）
          reaction: data[i][33],               // 反应计划标识（原reaction）

          // 产品图号（新增字段）
          drawing: this.secondTree,                      // 需补充data索引

          // 工序号（修改点：字段名改为下划线格式）
          op: this.thirdTree,                            // 工序号（原op）

          // 车间名称相关字段（多语言字段组）
          workshop: workshop,                     // 中文（原workshop）

          // 记录顺序号（修改点：字段名改为下划线格式）
          order_number: i,                  // 记录顺序（原orderNumber）

          // 系统维护字段（新增字段）
          sys_deleted:0,                    //删除标记位
          creator: this.useName+'/'+this.useId, // 自有编辑人（新增字段）
        })
      }
      //进行数据校验，并且返回错误
      //校验是否最后一行是备注，这个是需要删除的
      //第二遍：
      //第一步：对一些需要从上到下复制的数据进行赋值
      for (let i = 1; i < this.controlPlanDataExcel.length; i++) {
        if (this.controlPlanDataExcel[i].operation==='' || this.controlPlanDataExcel[i].operation===undefined || this.controlPlanDataExcel[i].operation===null){
          //过程名称／操作描述 是空的，进行赋值
          this.controlPlanDataExcel[i].operation=this.controlPlanDataExcel[i-1].operation
          this.controlPlanDataExcel[i].operation_english=this.controlPlanDataExcel[i-1].operation_english
          this.controlPlanDataExcel[i].operation_russian=this.controlPlanDataExcel[i-1].operation_russian
        }
        //机器、装置夹具、工装
        if (this.controlPlanDataExcel[i].device==='' || this.controlPlanDataExcel[i].device===undefined || this.controlPlanDataExcel[i].device===null){
          this.controlPlanDataExcel[i].device=this.controlPlanDataExcel[i-1].device
          this.controlPlanDataExcel[i].device_english=this.controlPlanDataExcel[i-1].device_english
          this.controlPlanDataExcel[i].device_russian=this.controlPlanDataExcel[i-1].device_russian
        }
      }
    },
    //上传EXCEL文件失败的函数
    handleUploadError(err, file, fileList) {
      // 处理上传失败逻辑
      console.error('上传失败:', err,file,fileList)
      this.$message.error('文件上传失败')
    },

    //辅助函数：根据两个字符串类型的字段，查询分别等于某一值的数据(控制计划的表）
    async queryThreeFieldControlPlan(firstFieldName, firstFieldVal, secondFieldName, secondFieldVal, thirdFieldName, thirdFieldVal) {
      const result = await this.$request.post('/queryThreeFieldControlPlanControlPlanNew', {
        firstFieldName: firstFieldName,
        firstFieldVal: firstFieldVal,
        secondFieldName:secondFieldName,
        secondFieldVal:secondFieldVal,
        thirdFieldName:thirdFieldName,
        thirdFieldVal:thirdFieldVal,
      })
      if (result.code === 401) {
        // 未登录，跳转到登录页面并提示
        this.$router.push('UserLogin');
        alert("您未登录，请登录");
      } else {
        // 成功，直接返回 result.data
        return result.data;
      }
    }
  },
  mounted() {
    this.inquiry()
    this.selectTree = -1
  },
}
</script>

<style scoped>
/* 主体左侧的工作步骤栏用到的数据包围的div的样式*/

.el-footer {
  background-color: #ffffff;
  color: #333;
  text-align: center;
  border-width: 3px; /* 设置边框宽度为3像素 */
  border-color: blue; /* 设置边框颜色为蓝色 */
  border-style: solid; /* 设置边框样式为实线 */
  padding: 10px; /* 添加内边距 */
  border-left-color: white;
  border-top: white;
}

.el-aside {
  background-color: #ffffff;
  color: #333;
  text-align: center;
  border-width: 3px; /* 设置边框宽度为3像素 */
  border-color: blue; /* 设置边框颜色为蓝色 */
  border-style: solid; /* 设置边框样式为实线 */
  padding: 10px; /* 添加内边距 */
  height: 89vh;
}

.el-main {
  color: #333;
  text-align: center;
  border-width: 3px; /* 设置边框宽度为3像素 */
  border-color: blue; /* 设置边框颜色为蓝色 */
  border-left-color: white;
  border-style: solid; /* 设置边框样式为实线 */
  padding: 10px; /* 添加内边距 */
  overflow: auto;
}

body > .el-container {
  margin-bottom: 40px;
}

.el-container:nth-child(5) .el-aside,
.el-container:nth-child(6) .el-aside {
  line-height: 260px;
}

.el-container:nth-child(7) .el-aside {
  line-height: 320px;
}

.headMain{
  color: #ffffff; /* 设置字体颜色为红色 */
  font-size: 18px;
}
.center-text {
  /* 使用 margin-left 和 margin-right auto 来实现居中效果 */
  margin-left: auto;
  margin-right: auto;
  /* 注意：如果 header 内只有这两个元素，你可能不需要 margin-right: auto */
}
.el-container {
  overflow: auto; /* 自动显示滚动条当内容溢出时 */
  /* 或者 */
  overflow-x: auto; /* 仅水平滚动 */
  overflow-y: auto; /* 仅垂直滚动 */
}
.UploadS{
  border-width: 1px; /* 设置边框宽度为3像素 */
  border-color: blue; /* 设置边框颜色为蓝色 */
  border-style: solid; /* 设置边框样式为虚线 */
  padding: 10px; /* 添加内边距 */
}
.el-input {
  width: 700px;
}

::v-deep .el-textarea__inner {
  font-family: Arial, Roboto, sans-serif;
  letter-spacing: normal;
}
/*自定义样式*/
</style>